import time


class FillCsv(object):
    def fill_csv(self, csv, platfrom):
        date = time.strftime('%Y-%m-%d', time.localtime())
        week = time.strftime('%a', time.localtime())
        hour = str(time.strftime('%H', time.localtime()))
        if hour[0] == 0:
            hour = hour[1]
        csv['date'] = date
        csv['week'] = week
        csv['hour'] = hour + '点'

        csv['platform'] = platfrom

        csv = csv.drop_duplicates('name')
        return csv